#ifndef SVMCLASSIFIER_H_
#define SVMCLASSIFIER_H_
#include "./Classifier.h"
//#include "./mysvm.h"
#include "./orgsvm.h"
//#include "./SVMClassifier.cpp"

namespace findobject{
class SVMClassifier: public Classifier {
public:

	struct svm_parameter param;
	struct svm_problem prob;
	struct svm_model *model;
	struct svm_node *x_space;

	float scaling;
	int cross_validation;
	int nr_fold;
	FeatureResponse ** validation_target; 
	FeatureResponse ** validation_data;
	int validation_nr_data;
	SVMClassifier();
	~SVMClassifier();
	void train(FeatureResponse ** target, FeatureResponse ** data,float * data_weights, int nr_data);
	FeatureResponse * evaluate(FeatureResponse * data);
	float estimate_error(FeatureResponse ** target, FeatureResponse ** data, int nr_data);
	void save(char * path);
	bool load(char * path);
	int getCost();

};
};
#endif
